From: Jasper St. Pierre Date: Wed, 5 Sep 2012 16:46:55 +0000 (-0300) Subject: autorunManager: Fix another regression X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~1013^2^2~5927 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=457fb604ddeede1ec4d5b99e31ed280f3f2db0f5;p=gnome-shell.git autorunManager: Fix another regression We may not have a resident source to destroy if no mounts are found. --- diff --git a/js/ui/components/autorunManager.js b/js/ui/components/autorunManager.js index cf75cb11c..38f93bc8c 100644 --- a/js/ui/components/autorunManager.js +++ b/js/ui/components/autorunManager.js @@ -169,7 +169,8 @@ const AutorunManager = new Lang.Class({ }, disable: function() { - this._residentSource.destroy(); + if (this._residentSource) + this._residentSource.destroy(); this._volumeMonitor.disconnect(this._mountAddedId); this._volumeMonitor.disconnect(this._mountRemovedId); },